package com.some;

import java.util.Scanner;

public class JingDong01 {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int b = sc.nextInt();
        if (a - b > 1) {
            System.out.print(-1);
        } else if (a > b) {
            System.out.print("1 ");
            for (int i = 0; i < b; i++) {
                System.out.print("2 1 ");
            }

        }else if (a < b) {
            for (int i = 0; i < a; i++) {
                System.out.print("1 2 ");
            }
            for (int i = 0; i < (b - a); i++) {
                System.out.print("2 ");
            }

        }
        else {
            for (int i = 0; i < a; i++) {
                System.out.print("1 2 ");
            }
        }
    }
}
